package com.hengfoxwolf.definerecyclerviewlayoutmanagerdemo
import android.os.Bundle
import androidx.recyclerview.widget.LinearLayoutManager
import com.hengfoxwolf.bannerdemo.BaseActivity
import com.hengfoxwolf.definerecyclerviewlayoutmanagerdemo.databinding.ActivityMainBinding
import com.hengfoxwolf.definerecyclerviewlayoutmanagerdemo.define.VerticalItemDecoration
import com.hengfoxwolf.definerecyclerviewlayoutmanagerdemo.define.VerticalLayoutManager

class MainActivity : BaseActivity<ActivityMainBinding>(ActivityMainBinding::inflate) {

    override fun init(savedInstanceState: Bundle?) {
        mBinding.contentRv.apply {
            layoutManager = VerticalLayoutManager()
            //layoutManager = LinearLayoutManager(context)
            addItemDecoration(VerticalItemDecoration(context))
            adapter = ContentRvAdapter(DataFactory.getDataSet())
        }
    }

    companion object {
        const val TAG = "MainActivity"
    }

}